Media Access Control (MAC) address is a unique number for identifying a network adapter after it is manufactured. Provider Backbone Bridges (PBB) (also known as Mac-in-Mac), together with QinQ (a transmission technology using an inner-layer 802.1Q tag encapsulated with an outer-layer 802.1Q tag), make it possible for the whole transmission network (Layer 2 network) to base on the Ethernet architecture, thereby allowing Metropolitan Area Network (MAN) and even Wide Area Network (WAN) to be realized by Ethernet technology from the access layer through the aggregation layer to the backbone layer. Thus, PBB is a crucial trend in Ethernet development, because Ethernet is of low cost and easy to use. With the advance of Mac-in-Mac technology and carrier Ethernet related features, such as the improvement on Quality of Service (QoS) and Operation Administration and Maintenance (OAM), MAN Ethernet and WAN Ethernet will be developed rapidly and Mac-in-Mac technology will get wider and wider applications.
Mac-in-Mac technology, capable of solving the scalability problem of Ethernet, is mainly applied to provider backbone network, and also applied to similar situations, such as the access layer and the aggregation layer. Mac-in-Mac differs from QinQ mainly in that: QinQ requires that all of the nodes learn a user's MAC address, which imposes a strict requirement on the nodes; while for Mac-in-Mac it only needs to maintain a user's address at the edge nodes.
FIG. 1 illustrates a typical example of applying Mac-in-Mac in networking. Here, the Mac-in-Mac technology is used in the backbone network. This means the backbone edge nodes support Mac-in-Mac, while the intermediate nodes are not required to support Mac-in-Mac. The intermediate nodes can be ordinarily switches supporting 802.1Q. Network-Provider Edge (N-PE) supports both Mac-in-Mac and QinQ, while the access layer only supports QinQ. The backbone layer and the access layer perform Spanning Tree Protocol (STP), respectively, to create their respective forwarding trees.
During the transmission of a user packet in a network, the detailed process is as follows:
After a user accesses a User Provider Edge (U-PE), different Virtual Local Area Network tags (designated as S-VLAN) are assigned to the user, according to the service type or the user type. There are 4094 total tags for S-VLAN. The user packet is encapsulated by means of QinQ, and then goes through the following transformation:
C-DAC-SAC-TAGDATAC-FCS C-DAC-SAS-TAGC-TAGDATAFCSThe symbols are defined as follows:C-DA: customer destination MAC address;C-SA: customer source MAC address;C-TAG: customer 802.1Q tag;S-TAG: service 802.1Q tagDATA: customer data;C-FCS: customer check sum; andFCS: Frame check sum.
When the packet arrives at N-PE, the address of the related backbone bridge edge node may be found, according to the customer destination address. Accordingly, Backbone Destination Address (B-DA) and Backbone Source Address (B-SA) are inserted in the packet. Meanwhile, Service Instance TAG (I-TAG) and Backbone VLAN TAG (B-TAG) fields are inserted in the packet. The I-TAG, as an inner tag, provides a Service Instance ID (SID) having at least 20 bits, for indicating various service instances. B-TAG, as an outer tag, indicates the various service types provided by the backbone provider (such as audio, video, and so on), or indicates different domains or different service providers. According to B-DA, B-SA, and B-TAG, the backbone nodes perform forwarding, which is actually equivalent to establishing a tunnel.
There are two ways to insert B-TAG and I-TAG.
1. S-TAG mode: A S-TAG of a packet is first identified, and then the S-TAG is mapped to an I-TAG that is found by searching an internal mapping table. Because the function of I-TAG is same as that of S-TAG, the transformed packet no longer carries S-TAG, and the format of the transformed packet is as follows:
B-DAB-SAB-TAGI-C-DAC-SAC-DATAB-TAGTAGFCS
2. Transparent mode: it neither processes the S-TAG of the packet, nor performs the related mapping. All of the packets are assigned with the same I-TAG and B-TAG for transmission. The user packet (including S-TAG) is transmitted transparently without any modification. The format of the packet is shown as follows:
B-B-B-I-C-C-S-C-DATAFCSB-DASATAGTAGDASATAGTAGFCS
When the customer data arrives at the peer backbone node, B-DA, B-SA, B-TAG, and I-TAG fields are removed. If it is in the S-TAG mode, a S-TAG may be obtained by searching the mapping table with reference to the I-TAG, and then the packet is re-encapsulated. If it is in the transparent mode, TAG mapping is not required anymore. After the packet is processed, it is directly forwarded to a U-PE, according to C-DA. The U-PE subsequently removes S-TAG and forwards the packet to the user.
In practical applications, the backbone network may be very huge. To solve this problem, the backbone network is divided into different layers, each of which is further partitioned into different domains, and various B-TAGs are assigned for the respective domains in each different layer. FIG. 2 shows a Mac-in-Mac hierarchical application in the related art, in which the backbone network is divided into two layers, i.e. a first layer and a second layer. The first layer is further divided into four domains A, B, C, and D, each of which has its own B-TAG. During the data forwarding among the different domains, it is required to replace the corresponding B-TAG, while keeping the I-TAG unchanged during the whole data transmission procedure.
The devices in FIG. 2 are respectively:
BB: Backbone Provider Bridge;
PB: Provider Bridge (as defined by 802.1ad);
BB PB: Backbone Provider Bridge Edge, i.e. the edge devices between the backbone network and network provider; and
BB BB: Backbone Provider Bridge Layer Edge, i.e. the edge device between the backbone network and network provider layer.
The processing on a user packet is shown as follows:
At PB, the user packet is encapsulated in the form of QinQ. At BB PB, the S-TAG of the user packet is mapped to an I-TAG of Mac-in-Mac, which consists of a SID having at least 20 bits, and at last a B-TAG is encapsulated in the packet for transmission. At BB BB, the original B-TAG is mapped to a new B-TAG, and the packet is transmitted to the peer BB BB, and then transmitted to the peer BB PB via B-TAG mapping. The peer BB PB maps the I-TAG back to S-TAG and removes the Mac-in-Mac header, then transmits the packet to the peer PB finally. The peer PB processes and transmits the packet to the peer user.
In the technical solution of the related art, each domain of the various network layers cannot decide the allocation of I-TAG on its own. The I-TAG is globally valid in the backbone network and kept unchanged, therefore I-TAG cannot be extended anymore.